<!DOCTYPE html>
<html lang="en">
<head>
<title>{:C('WEB_TITLE')}</title>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="__CONTENT__/admin/css/bootstrap.min.css" />
<link rel="stylesheet"
	href="__CONTENT__/admin/css/bootstrap-responsive.min.css" />
<link rel="stylesheet" href="__CONTENT__/admin/css/fullcalendar.css" />
<link rel="stylesheet" href="__CONTENT__/admin/css/matrix-style.css" />
<link rel="stylesheet" href="__CONTENT__/admin/css/matrix-media.css" />
<link href="__CONTENT__/admin/font-awesome/css/font-awesome.css"
	rel="stylesheet" />
<link rel="stylesheet" href="__CONTENT__/admin/css/jquery.gritter.css" />
<link href='http://fonts.useso.com/css?family=Open+Sans:400,700,800'
	rel='stylesheet' type='text/css'>
</head>
<body style="background-color: #2E363F;">
	<div id="header">
		<h1>
			<a href="dashboard.html">Admin</a>
		</h1>
	</div>
	<div id="user-nav" class="navbar navbar-inverse">
		<ul class="nav">
			<li class="dropdown" id="profile-messages"><a title="" href="#"
				data-toggle="dropdown" data-target="#profile-messages"
				class="dropdown-toggle"><i class="icon icon-user"></i> <span
					class="text">{$_SESSION['admin']['username']}</span><b class="caret"></b></a>
				<ul class="dropdown-menu">
					<li><a href="{:U('Index/updatePwd')}" target="main"><i class="icon-key"></i>modify password</a></li>
				</ul></li>
			<li class=""><a title="" href="{:U('Public/layout')}"><i
					class="icon icon-share-alt"></i> <span class="text">exit</span></a></li>
		</ul>
	</div>
	<div id="sidebar">
		<a href="#" class="visible-phone"><i class="icon icon-home"></i>
			Dashboard</a>
		<ul>
			{foreach $_SESSION['menuList'] as $k=>$v}
			<li class="submenu{if $k==0} active{/if}"><a href="#"><i class="icon icon-home"></i>
					<span>{$v['name']}</span></a>
				<ul>
					{foreach $v['children'] as $item}
					<li><a href="{:U($item['url'])}" target="main">{$item['name']}</a></li>
					{/foreach}
				</ul></li> {/foreach}
		</ul>
	</div>
	<div id="content" style="margin-left: 220px;">
		<!--breadcrumbs-->
		<div id="content-header">
			<div id="breadcrumb">
				<a href="#">Home</a>
			</div>
		</div>
		<iframe name="main" src="{:U('main')}" scrolling="yes" width="100%"
			height="100%" frameborder="0" noresize=""> </iframe>
	</div>

	<!--end-main-container-part-->

	<!--Footer-part-->

	<div class="row-fluid">
		<div id="footer" class="span12">{:C('COPYRIGHT')}</div>
	</div>

	<!--end-Footer-part-->

	<script src="__CONTENT__/admin/js/excanvas.min.js"></script>
	<script src="__CONTENT__/admin/js/jquery.min.js"></script>
	<script src="__CONTENT__/admin/js/jquery.ui.custom.js"></script>
	<script src="__CONTENT__/admin/js/bootstrap.min.js"></script>
	<script src="__CONTENT__/admin/js/jquery.flot.min.js"></script>
	<script src="__CONTENT__/admin/js/jquery.flot.resize.min.js"></script>
	<script src="__CONTENT__/admin/js/jquery.peity.min.js"></script>
	<script src="__CONTENT__/admin/js/fullcalendar.min.js"></script>
	<script src="__CONTENT__/admin/js/matrix.js"></script>
	<script src="__CONTENT__/admin/js/jquery.gritter.min.js"></script>
	<script src="__CONTENT__/admin/js/matrix.chat.js"></script>
	<script src="__CONTENT__/admin/js/jquery.validate.js"></script>
	<script src="__CONTENT__/admin/js/matrix.form_validation.js"></script>
	<script src="__CONTENT__/admin/js/jquery.wizard.js"></script>
	<script src="__CONTENT__/admin/js/jquery.uniform.js"></script>
	<script src="__CONTENT__/admin/js/select2.min.js"></script>
	<script src="__CONTENT__/admin/js/matrix.popover.js"></script>
	<script src="__CONTENT__/admin/js/jquery.dataTables.min.js"></script>
	<script src="__CONTENT__/admin/js/matrix.tables.js"></script>

	<script type="text/javascript">
		// This function is called from the pop-up menus to transfer to
		// a different page. Ignore if the value returned is a null string:
		function goPage(newURL) {

			// if url is empty, skip the menu dividers and reset the menu selection to default
			if (newURL != "") {

				// if url is "-", it is this page -- reset the menu:
				if (newURL == "-") {
					resetMenu();
				}
				// else, send page to designated URL            
				else {
					document.location.href = newURL;
				}
			}
		}

		// resets the menu selection upon entry to this page:
		function resetMenu() {
			document.gomenu.selector.selectedIndex = 2;
		}
		$(function() {
			var thisheight = $(document).height() + 30;
			$("iframe[name='main']").height(thisheight);
			$("li.submenu ul li a").click(function(){
				$("#breadcrumb a").html($(this).html());
				$("iframe[name='main']").attr("src",$(this).attr("href"));
				return false;
			});
		});
	</script>
</body>
</html>
